<!DOCTYPE html>
<html lang="zh-cn"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<meta http-equiv="Content-Language" content="zh-CN">
<meta name="author" content="管雷鸣">
<title>DEMO</title>
<script src="https://res.zvo.cn/msg/msg.js"></script>
<script src="https://res.zvo.cn/kefu/kefu.js"></script>
<link rel="stylesheet" type="text/css" href="https://res.zvo.cn/kefu/css/style.css" media="screen">
</head>
<body>
<script type="text/javascript">
var host = 'https://api.kefu.leimingyun.com/';
var socketUrl = 'wss://api.kefu.leimingyun.com/websocket';
//var host = 'http://localhost:8080/';
//var socketUrl = 'ws://localhost:8081/';
kefu.extend.order = {};
kefu.extend.goods = {};

//kefu.js 接口设置
kefu.api.getMyUser = host+'/kefu/chat/user/init.json';
//kefu.api.getMyUser = host+'/kefu/inset/login.json';	//三方系统对接
kefu.api.getChatOtherUser = host+'/kefu/chat/user/getUserById.json';
kefu.api.chatLog = host+'/kefu/chat/log/log.json';
kefu.api.uploadImage = host+'/kefu/chat/file/uploadImage.json';

//kefu.js 初始化
kefu.init();
kefu.getMyUser(function(data){
	kefu.user = data.user;
	kefu.user.otherUserId = data.otherUserId;
	kefu.socket.connect(socketUrl);	//建立 socket 通讯
});

//填写上你的坐席id即可。
kefu.ui.chat.entry("365fef747a9e493fb631b621ee36eed1");

</script>

</body>
</html>